﻿<ul>
    <!--登录模块-->
    @if (Request.IsAuthenticated)
    {
        <li>欢迎您 <a@* href="@Url.Content("~/Account/Center")"*@ target="_blank"><b>@Context.User.Identity.Name</b></a></li>
        if(Roles.IsUserInRole("administrators"))
        {
            @*如果用户为管理员*@
          <li>@Html.ActionLink("管理中心","Index","Admin",null, new { target="_blank"})</li>  
        }
        <li><a href="javascript:;" id="btnLogOff">注销</a></li>
        
    }
    else
    {
        <li><a href="javascript:;" class="btnLogin">登录</a></li>
        <li><a href="javascript:;" id="btnRegister">注册</a></li>
        <div id="dialogLogin" title="登录" style="display:none;">
            @{Html.RenderAction("AjaxLogin", "Account");}
        </div>
        <div id="dialogRegister" title="注册新用户" style="display:none;">
            <iframe id="myFrame" src="" width="98%" height="96%" frameborder="0"></iframe>
        </div>
    }
    
</ul>
<script type="text/javascript">
    var serverPath="@Url.Content("~/")";
    var loginPartialUrl="@Url.Content("~/Account/LogOnPartial")";
</script>
@Content.Script("VOD/Login.js", Url)